Magento Get URL with or without secure path according to current URL protocol
Use the following format to get the URL based on protocol.
Mage::getUrl(‘yourpath’, array(‘_secure’ => Mage::app()->getFrontController()->getRequest()->isSecure()));
Leave a Comment